import numpy as np
import pandas as pd

#获取头和尾的数据，默认5条
def use_head_tail():
    long_series = pd.Series(np.random.randn(1000))
    print(long_series.head())
    print(long_series.tail(10))

if __name__ == '__main__':
    #index = pd.date_range('1/1/2000', periods=8)
    #s = pd.Series(np.random.randn(5), index=['a', 'b', 'c', 'd', 'e'])
    #df = pd.DataFrame(np.random.randn(8, 3), index=index, columns=['A', 'B', 'C'])

    use_head_tail()

